package com.mszlu.blog.admin.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.mszlu.blog.admin.pojo.Permission;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * Created with IntelliJ IDEA.
 * User: SJP
 * Date: 2022/3/7
 * Time: 19:36
 *
 * @author sjp
 * Description: No Description
 */
public interface PermissionMapper extends BaseMapper<Permission> {
    @Select("select * from ms_permission where id in (select permission_id from ms_admin_permission where admin_id = #{adminId})")
    List<Permission> findPermissionByAdmin(Long adminId);
}
